package com.xnyzc.lhy.mis.service.worksheet;

import com.baomidou.mybatisplus.extension.service.IService;
import com.xnyzc.lhy.common.entity.DiDiRv;
import com.xnyzc.lhy.common.entity.WorksheetRv;
import com.xnyzc.lhy.mis.entity.order.OaCOrderPersonal;
import com.xnyzc.lhy.mis.entity.param.worksheet.didi.ChangePriceParam;
import com.xnyzc.lhy.mis.entity.param.worksheet.softbar.HeliPhoneUrlResult;
import com.xnyzc.lhy.mis.entity.param.worksheet.softbar.SoftPhoneUserInfoResult;
import com.xnyzc.lhy.mis.entity.worksheet.OaSysWorksheet;
import com.xnyzc.lhy.resource.entity.worksheet.param.*;
import com.xnyzc.lhy.resource.entity.worksheet.param.heli.FromHeliWorksheetParam;

import java.math.BigDecimal;

/**
 * <p>
 * 工单信息表 服务类
 * </p>
 *
 * @author haoyfa
 * @since 2019-11-04
 */
public interface IWorksheetService extends IService<OaSysWorksheet> {
    /**
     * 1.取消订单
     *
     * @param worksheetCancelOrderParam
     * @return
     */
    DiDiRv cancelOrder(WorksheetCancelOrderParam worksheetCancelOrderParam);

    /**
     * 2.关闭订单
     *
     * @param worksheetCloseOrderParam
     * @return
     */
    DiDiRv getCloseOrder(WorksheetCloseOrderParam worksheetCloseOrderParam);

    /**
     * 3.订单改价接口
     *
     * @param param
     * @return
     */
    DiDiRv getChangePrice(ChangePriceParam param);

    /**
     * 4.退款接口
     *
     * @param priceParam
     * @return
     */
    DiDiRv getBillRefund(WorksheetGetBillRefundParam priceParam);

    /**
     * 5.免单接口
     *
     * @param worksheetFreeChargeParam
     * @return
     */
    DiDiRv getFreeCharge(WorksheetFreeChargeParam worksheetFreeChargeParam);

    /**
     * 6.工单状态同步第三方（滴滴）接口
     *
     * @param worksheetUpdateWorksheetParam
     * @return
     */
    WorksheetRv updateWorksheet(WorksheetUpdateWorksheetParam worksheetUpdateWorksheetParam);

    /**
     * 7.查询订单详情接口
     *
     * @param worksheetGetOrderPersonalDetailParam
     * @return
     */
    WorksheetRv getOrderPersonalDetail(WorksheetGetOrderPersonalDetailParam worksheetGetOrderPersonalDetailParam);

    /**
     * 8.查询订单列表接口
     *
     * @param worksheetgetOrderPersonalListParam
     * @return
     */
    WorksheetRv getOrderPersonalList(WorksheetgetOrderPersonalListParam worksheetgetOrderPersonalListParam);

    /**
     * 9.客服标记司机违规
     *
     * @param worksheetetDriverPenaltyDetailParam
     * @return
     */
    WorksheetRv setDriverPenaltyDetail(WorksheetetDriverPenaltyDetailParam worksheetetDriverPenaltyDetailParam);

    /**
     * 10.司机信息接口
     *
     * @param worksheetetGetDriverDetailParam
     * @return
     */
    WorksheetRv getDriverDetail(WorksheetetGetDriverDetailParam worksheetetGetDriverDetailParam);

    /**
     * 创建工单信息
     *
     * @param fromHeliWorksheetParam
     * @return
     */
    WorksheetRv createWorksheet(FromHeliWorksheetParam fromHeliWorksheetParam);

    /**
     * 获取当前的登录用户的电话条用户信息
     *
     * @return
     */
    SoftPhoneUserInfoResult getSoftPhoneUserInfo();

    /**
     * 判断当前用户是否有电话条权限
     *
     * @return
     */
    Boolean hasPhoneBarAuth();

    /**
     * 获取订单状态
     * @param worksheetGetOrderPersonalStatusParam
     * @return
     */
    WorksheetRv getOrderPersonalStatus(WorksheetGetOrderPersonalStatusParam worksheetGetOrderPersonalStatusParam);

    /**
     * 更新钱包记录
     * @param driverId
     * @param amount
     * @param amountRemark
     */
    void updateDriverWallet(Long driverId, BigDecimal amount, String amountRemark);

    /**
     * 客服关单
     * @param oaCOrderPersonal
     */
    void closeOrderStatus(OaCOrderPersonal oaCOrderPersonal);


    /**
     * 获取合力电话条地址
     */
    HeliPhoneUrlResult getHeliPhoneUrl();

}
